package router

import (
	"github.com/gin-gonic/gin"
)

func LoadRouter(r *gin.Engine) {
	r.Use(Cors())
	v1 := r.Group("/v1")
	{
		api := v1.Group("api")
		UserRouter(api)
	}
}
func Cors() gin.HandlerFunc {
	return func(c *gin.Context) {
		c.Header("Access-Control-Allow-Origin", "*")
	}
}
